package com.app.micaihu.view.home.arms.adapter

import android.widget.ImageView
import com.app.micaihu.R
import com.app.micaihu.view.bean.Arms
import com.app.micaihu.view.utils.loadImage
import com.chad.library.adapter.base.BaseQuickAdapter
import com.chad.library.adapter.base.module.LoadMoreModule
import com.chad.library.adapter.base.viewholder.BaseViewHolder

class ArmsListAdapter : BaseQuickAdapter<Arms.Button, BaseViewHolder>(R.layout.arms_list_item), LoadMoreModule {

    override fun convert(holder: BaseViewHolder, item: Arms.Button) {
        holder.getView<ImageView>(R.id.ivImage).loadImage(item.logo, R.mipmap.image_default_round)
        holder.setText(R.id.tvTitle, item.title)
        holder.setText(R.id.tvDesc, item.desc)
    }
}